Main Page | Data Structures | File List | Data Fields | Globals

BustaModelTipJar Class Reference

Tip Jar. More...

#include <BustaModelTipJar.h>


Public Member Functions

 BustaModelTipJar ()
 Constructor.
 BustaModelTipJar (int s)
 Constructor.
 ~BustaModelTipJar ()
 Destructor.
int getSize ()
 Gets size of tipjar.
void setSize (int s)
 Sets size of tipjar.
int getTips ()
 Returns tips in jar.
void addTips (int t)
 adds specified amount to the tipjar;
void setTips (int tipAmount)
 Sets the amount of tips in the tip jar.
int subtractTips (int t)
 removes tips from tipjar.
bool isfull ()
 Returns true if tipjar is full.


Detailed Description

Tip Jar.

Tip jar contains tips from customers, has specific amount that it take to fill, and cannot overflow


Constructor & Destructor Documentation

BustaModelTipJar::BustaModelTipJar  ) 
 

Constructor.

Initializes variables

BustaModelTipJar::BustaModelTipJar int  s  ) 
 

Constructor.

Initializes variables with fullamount s

BustaModelTipJar::~BustaModelTipJar  ) 
 

Destructor.

Destructor


Member Function Documentation

void BustaModelTipJar::addTips int  t  ) 
 

adds specified amount to the tipjar;

can only add tips up until full

int BustaModelTipJar::getSize  ) 
 

Gets size of tipjar.

Gets the amount that can fit in the tip jar

int BustaModelTipJar::getTips  ) 
 

Returns tips in jar.

returns the amount of tips in the tipjar

bool BustaModelTipJar::isfull  ) 
 

Returns true if tipjar is full.

returns true if tipjar is full

void BustaModelTipJar::setSize int  s  ) 
 

Sets size of tipjar.

Sets the amount that can fit in the tip jar

void BustaModelTipJar::setTips int  tipAmount  ) 
 

Sets the amount of tips in the tip jar.

Sets the amount of tips in the tip jar. If the new tip amount exceeds the size of the tip jar the tip amount is set to the size of the tip jar.

Parameters:
tipAmount The amount of tips to assign to the jar

int BustaModelTipJar::subtractTips int  t  ) 
 

removes tips from tipjar.

returns amount actually subtracted


Generated on Sun Aug 14 22:24:56 2005 for BustaSandwich Models by  doxygen 1.4.2-20050421